package pp.strategy.task;

import com.alibaba.fastjson.JSONArray;
import pp.IProjectJobStrategy;
import properties.AutoBGProperties;

public class AutoTaskStrategy implements IProjectJobStrategy {
    @Override
    public Task jobId(JSONArray jsonArray, AutoBGProperties autoBGProperties) {
        String id = jsonArray.getJSONObject(0).getString("id");
        String name = jsonArray.getJSONObject(0).getString("name");
        return new Task(id,name);
    }
}
